home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
TPUG - Toronto PET Users Group
/
TPUG Users Group CD
/
TPUG Users Group CD.iso
/
C64
/
U-Utilities
/
(c)u3.d64
/
diskette mod.c
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2007-02-11
|
2KB
|
46 lines
100 PRINT"[147]DISKETTE VIEWER/CHANGER**JIM BUTTERFIELD"
110 PRINT" CAUTION - USE CARE - THIS PROGRAM"
115 PRINT "ADAPTED BY BRIAN SCHOTT TO FIX DISKETTE SECTORS"
118 REM 1041 NORTH HILLS DRIVE, DECATUR, GEORGIA, 30033
119 REM MAY 1983, FOR C64
120 PRINT" CAN WRECK YOUR DISKETTE IF USED"
130 PRINT" WITHOUT CARE & UNDERSTANDING!"
135 PRINT"DO YOU WANT INSTRUCTIONS"
136 GETY$:IFY$=""THEN136
137 IFY$<>"N"THEN1200
140 POKE53281,11
160 S1=16
170 S2=255:S3=37
180 DIM A(255)
190 B$=CHR$(17):D$="0"
210 OPEN 15,8,15,"I"+D$:GOSUB500
220 OPEN2,8,2,"#0":GOSUB500
230 PRINT" TRACK,SECTOR 0,0[157][157][157][157][157]";
240 INPUTT,S
250 IFT<1ORT>35THENCLOSE2:CLOSE15:END
260 PRINT" WORKING ":PRINT#15,"U1:2,";D$;T;S:GOSUB500
275 PRINT"[147]";
280 FORJ=0TO255
300 GET#2,A$:IFA$=""THENA$=CHR$(0)
310 A(J)=ASC(A$):NEXTJ
320 P=0:CL=1
330 PRINT"[147]TRACK";T;"SECTOR";S
340 FORJ=PTOP+S2STEPS1:PRINT"]";
350 V=J:GOSUB800:K$="":PRINT"- ";:FORK=0TOS1-1:V=A(J+K):GOSUB800:K$="":CL=1-CL
355 PRINTCHR$(18);:IFCL=1THENPRINTCHR$(146);
356 REM IF YOU PREFER CHANGE 18 TO 144 AND CHANGE 146 TO 144 IN STATEMENT 355
360 NEXT K:PRINT"-":NEXTJ
365 PRINT"";
370 PRINT"CHANGE THE FIRST CHARACTER TO [ TO READ CHANGED SCREEN ONTO THE DISK"
380 PRINT"CHANGE THE FIRST CHARACTER TO \ TO ABORT THIS PROCESS"
390 OPEN1,3:CMD1
440 INPUTC$:PRINT;:Z=ASC(C$):C$=C$
450 PRINT#1:CLOSE1
460 IFZ=91GOTO530
470 IFZ=93GOTO390
475 IFZ=147GOTO390
480 GOTO230
500 REM
510 INPUT#15,E,E$,E1,E2:IFE=0THENRETURN
520 PRINT"DISK ERROR:[146]"E;E